package cn.lightpm.controller.account;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.servlet.View;
import org.springframework.web.servlet.view.RedirectView;

import cn.lightpm.util.web.SiteDefs;

@Controller
public class LoginController {

	@RequestMapping(value = "/login", method = RequestMethod.GET)
	public String toLogin() {
		return "login";
	}

	@RequestMapping(value = "/", method = RequestMethod.GET)
	public View toHome() {
		return new RedirectView(SiteDefs.CONTEXT_NAME + "/user");
	}
}
